package com.tengju.bff.interfaces.covercharge.constant;

/**
 * 自认证状态
 */
public enum SelfCertificationStatus {

    // 0待审核 1通过 2拒绝 3终止
    WAITING_APPROVED(0,"待审核"),

    PASS(1,"通过"),

    REFUSE(2,"拒绝"),

    STOP(3,"终止")
    ;

    private SelfCertificationStatus(Integer code,String descriptioin){
       this.code=code;
       this.descriptioin=descriptioin;
    }




    private Integer code;
    private String descriptioin;

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getDescriptioin() {
        return descriptioin;
    }

    public void setDescriptioin(String descriptioin) {
        this.descriptioin = descriptioin;
    }

    public static SelfCertificationStatus getStatusDesc (Integer code){
        for(SelfCertificationStatus thisEnum : (SelfCertificationStatus.values())){
            if(thisEnum.getCode().equals(code)){//如果传入的code与此枚举code相同，则返回此枚举
                return thisEnum;
            }
        }
        return null;
    }
}
